<!DOCTYPE html>
<html>
<style type="text/css">
	.contract-pictures {
		top: 0;
		left: 0;
		width: 80px;
		height: 80px;
	}

	.uploader_box {
		display: flex;
		justify-content: center;
		margin: auto;
		height: 4rem;
		background-color: #FFFFFF;
	}

	.uploadMsg {
		height: 1.25rem;
		font-size: 0.5rem;
		margin: 10px 0px 0px 0px;
		line-height: 1.25rem;
		text-align: center;
		background-color: #FFFFFF;
		color: #333333;
		font-family: PingFangSC-Regular, PingFang SC;
	}

	.take_pic_btn {
		width: 344.95px;
		height: 50px;
		font-size: 0.5rem;
		font-weight: 600;
		line-height: 50px;
		border-radius: 0.38rem;
		text-align: center;
		margin: 20px 0px 0px 00px;
		font-family: PingFangSC-Semibold, PingFang SC;
		color: #FFFFFF;
		background: linear-gradient(318deg, #FF9100 0%, #FFA400 100%);
	}

	.mask {
		position: fixed;
		left: 0;
		top: 1.38rem;
		right: 0;
		bottom: 0;
		margin: auto;
		background-color: rgba(0, 0, 0, .7);
		z-index: 99;
	}

	.mask_msg {
		position: absolute;
		left: 0;
		right: 0;
		top: 0;
		bottom: 0;
		margin: auto;
		width: 8.75rem;
		height: 2.19rem;
		background: #FFFFFF;
		border-radius: 0.25rem;
		font-size: 0.5rem;
		text-align: center;
		line-height: 2.19rem;
	}

	.big_pic {
		height: 100%;
		display: flex;
		align-items: center;
		transform: scale(1);
		transition: all ease 0.2s;
	}
</style>

<head>
	<meta charset="utf-8" />
	<title>填写合作信息</title>
	<meta http-equiv="Content-type" content="textml; charset=utf-8" />
	<meta content="telephone=no" name="format-detection" />
	<meta name="x5-orientation" content="portrait">
	<meta name="screen-orientation" content="portrait">
	<meta name="viewport"
		content="width=device-width,height=device-height,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=yes">
	<meta http-equiv="X-UA-Compatible" content="ie=edge">
	<link rel="icon" href="data:;base64,=">
	<link rel="stylesheet" type="text/css" href="//img.ejiayou.com/activity/pages/ejiayoupay/ejiayou/css/reset.css" />
	<link rel="stylesheet" href="css/index.css" />
	<link rel="stylesheet" type="text/css" href="css/index_style.css" />
	<style type="text/css">
		.new-cell {
			background: #fff;
		}

		.van-cell__title {
			width: 98px !important;
		}

		.van-cell__value {
			color: #323233;
			text-align: left;
		}
	</style>
</head>

<body>
	<div id="app" v-cloak>
		<!--			<div class="tab_content">-->
		<!--				<div class="tab_item" @click="comeToBack">-->
		<!--					<span>审核信息</span>-->
		<!--				</div>-->
		<!--				<div class="tab_item tab_active">-->
		<!--					<span>补充信息</span>-->
		<!--				</div>-->
		<!--			</div>-->
		<div class="step_box">
			<img src="https://img.ejiayou.com/activity/jiguang_upload/img/step_active_six.png">
		</div>
		<van-cell value="结算基本信息"></van-cell>
		<div class="main_active">
			<van-form label-width="7em">
				<van-field v-model="accountName" label="油站对公账户名" placeholder="账户户名" label-width="7em"></van-field>
				<van-field v-model="bankBranch" label="油站账户支行" placeholder="开户支行名称" label-width="7em"></van-field>
				<van-field v-model="bankAccount" label="银行账户"></van-field>
				<van-field name="radio" label="账户类型">
					<template #input>
						<van-radio-group v-model="accountType" direction="horizontal">
							<van-radio name="1">企业户
								<template #icon="props">
									<img class="img-icon" :src="props.checked ? activeIcon : inactiveIcon" />
								</template>
							</van-radio>
							<van-radio name="0">个人户
								<template #icon="props">
									<img class="img-icon" :src="props.checked ? activeIcon : inactiveIcon" />
								</template>
							</van-radio>
						</van-radio-group>
					</template>
				</van-field>
				<van-field v-model="bankName" label="银行名称"></van-field>
				<van-field v-model="provinceName" readonly label="开户省份" right-icon="arrow"
					@click="showProvincePicker = true"></van-field>
				<van-field v-model="accountCityName" readonly label="开户城市" right-icon="arrow" @click="onShowCityPicker">
				</van-field>
				<!--          <van-cell title="开户省份" title-style="width: 98px;" class="new-cell" is-link :value="provinceName" @click="showProvincePicker = true"></van-cell>-->
				<!--          <van-cell title="开户城市" class="new-cell" is-link :value="openCityName" @click="showCityPicker = true"></van-cell>-->
				<!--          <van-field v-model="provinceName" label="开户省份"></van-field>-->
				<!--          <van-field v-model="openCityName" label="开户城市"></van-field>-->
				<!--					<van-field name="radio" label="油站日常活动">-->
				<!--						<template #input>-->
				<!--							<van-radio-group v-model="isActivity" direction="horizontal">-->
				<!--								<van-radio name="0">-->
				<!--									无-->
				<!--									<template #icon="props">-->
				<!--									  <img class="img-icon" :src="props.checked ? activeIcon : inactiveIcon" />-->
				<!--									</template>-->
				<!--								</van-radio>-->
				<!--								<van-radio name="1">有-->
				<!--									<template #icon="props">-->
				<!--									  <img class="img-icon" :src="props.checked ? activeIcon : inactiveIcon" />-->
				<!--									</template>-->
				<!--								</van-radio>-->
				<!--							</van-radio-group>-->
				<!--						</template>-->
				<!--					</van-field>-->
				<van-cell value="油站证件信息"></van-cell>
				<!-- <van-field name="" label="营业执照"> -->
				<van-field name="uploader" v-model="businesslicensePic" label="营业执照"
					:rules="[{validator: contractPicValidator1, message: '请上传营业执照' }]">
					<template #input>
						<!-- <van-uploader v-model="businesslicensePics" multiple :max-count="1" :after-read="afterBusinessPic">
							</van-uploader> -->
						<div class="contract-pictures" @click="selectPic(1)">
							<van-image fit="cover" :src="businesslicensePic">
								<template v-slot:loading>图片上传中</template>
							</van-image>
						</div>
					</template>
				</van-field>
				<!-- <van-field name="" class="van_field_long_length" label="开户许可证"> -->
				<van-field name="uploader" v-model="startbusinesslicensePic" class="van_field_long_length" label="开户许可证"
					:rules="[{validator: contractPicValidator2, message: '请上传开户许可证' }]">
					<template #input>
						<!-- <van-uploader v-model="startbusinesslicensePics" multiple :max-count="1" :after-read="afterStartBusinessPic" /> -->
						<div class="contract-pictures" @click="selectPic(2)">
							<van-image fit="cover" :src="startbusinesslicensePic">
								<template v-slot:loading>图片上传中</template>
							</van-image>
						</div>
					</template>
				</van-field>

				<!-- <van-field name="" class="van_field_long_length" label="法人身份证正面"> -->
				<van-field name="uploader" v-model="legalFrontPic" class="van_field_long_length" label="法人身份证正面"
					:rules="[{validator: contractPicValidator3, message: '请上传法人身份证正面' }]">

					<template #input>
						<!-- <van-uploader v-model="legalFrontPics" :after-read="afterLegalFrontPic" multiple :max-count="1" /> -->
						<div class="contract-pictures" @click="selectPic(3)">
							<van-image fit="cover" :src="legalFrontPic">
								<template v-slot:loading>图片上传中</template>
							</van-image>
						</div>
					</template>
				</van-field>
				<!-- <van-field name="" class="van_field_long_length" label="法人身份证反面"> -->
				<van-field name="uploader" v-model="legalReversePic" class="van_field_long_length" label="法人身份证反面"
					:rules="[{validator: contractPicValidator4, message: '请上传法人身份证反面' }]">
					<template #input>
						<!-- <van-uploader v-model="legalReversePics" :after-read="afterLegalReversePic" multiple :max-count="1" /> -->
						<div class="contract-pictures" @click="selectPic(4)">
							<van-image fit="cover" :src="legalReversePic">
								<template v-slot:loading>图片上传中</template>
							</van-image>
						</div>
					</template>
				</van-field>
				<!-- <van-field name="" class="van_field_long_length" label="油品经营危化证"> -->
				<van-field name="uploader" v-model="DangerousPic" class="van_field_long_length" label="油品经营危化证"
					:rules="[{validator: contractPicValidator5, message: '请上传油品经营危化证' }]">
					<template #input>
						<!-- <van-uploader v-model="DangerousPics" :after-read="afterDangerousPic" multiple :max-count="1" /> -->
						<div class="contract-pictures" @click="selectPic(5)">
							<van-image fit="cover" :src="DangerousPic">
								<template v-slot:loading>图片上传中</template>
							</van-image>
						</div>
					</template>
				</van-field>

				<div class="submit_box_step" v-if="!look_gd_text&&!from_page">
					<van-button square type="primary" native-type="button" @click="rebackToLast">上一步</van-button>
					<van-button square type="primary" native-type="submit" v-if="!look_gd" @click="saveComeToNext">确认申请
					</van-button>
					<!--            <van-button square type="primary" native-type="submit" v-if="!look_gd">保存并下一步</van-button>-->
					<van-button square class="xuxian_button" type="primary" native-type="button" @click="rejectGd"
						v-if="look_gd">驳回</van-button>
				</div>
				<div class="submit_box" v-if="look_gd && !look_gd_text">
					<van-button square type="primary" native-type="button" @click="applyPass">通过申请</van-button>
				</div>
				<div class="submit_box_step" v-if="from_page">
					<van-button square type="primary" native-type="button" @click="rebackToLast">上一步</van-button>
					<van-button square type="primary" native-type="button" @click="rebackUrl">关闭工单</van-button>
				</div>
				<div class="submit_box" v-if="sixBack == 1">
					<van-button square type="primary" native-type="button" @click="rebackUrl">上一步</van-button>
				</div>

			</van-form>
		</div>

		<div class="overlayMask" v-if="overlayShow" @touchmove.stop.prevent>
			<div class="wrapper">
				<div class="wrapper_info">
					<div class="wrapper_title">{{wrapperTitle}}</div>
					<div class="wrapper_yijian">审批意见：</div>
					<div class="wrapper_textarea">
						<textarea v-model="mytext" name="" placeholder="非必填" id="" cols="30"
							rows="10">{{mytext}}</textarea>
					</div>
					<div class="wrapper_between">
						<div class="wrapper_between_fl" @click="overlayShow=false">取消</div>
						<div class="wrapper_between_rg" @click="submitApproval">确认</div>
					</div>
				</div>
			</div>
		</div>

		<div class="overlayMask" v-if="nonstandardShow" @touchmove.stop.prevent>
			<div class="wrapper" @touchmove>
				<div class="wrapper_info">
					<div class="wrapper_title">非标准上线流程</div>
					<div class="wrapper_sub_title" v-if="standard_data.work_type == 3">
						您提交的申请为非标准上线流程，需要审核通过后，运营手动配置上线。预计上线时长5-10天。触发的非标规则如下：</div>
					<div class="wrapper_sub_title" v-if="standard_data.work_type == 2">
						您提交的申请为非标准上线流程，需要审核通过才能上线，预计上线时长3-5天。触发的非标规则如下：</div>
					<div class="wrapper_content">
						<div>
							<p v-for="(remark, remark_index) in standard_data.remark">
								{{remark_index+1}}.{{remark}}
							</p>
						</div>
					</div>
					<div class="wrapper_between">
						<div class="wrapper_between_fl" @click="nonstandardShow=false">取消</div>
						<div class="wrapper_between_rg" @click="applySure">确认申请</div>
					</div>
				</div>
			</div>
		</div>
		<van-popup v-model="showProvincePicker" round position="bottom">
			<van-picker show-toolbar :columns="provinceList" value-key="provinceName"
				@cancel="showProvincePicker = false" @confirm="provincePickerConfirm"></van-picker>
		</van-popup>
		<van-popup v-model="showCityPicker" round position="bottom">
			<van-picker show-toolbar :columns="cityList" value-key="cityName" @cancel="showCityPicker = false"
				@confirm="cityPickerConfirm"></van-picker>
		</van-popup>
		<!-- 拍摄示例层 -->
		<van-action-sheet v-model="showExamplePic" title="拍摄示例">
			<div>
				<van-swipe :autoplay="3000">
					<van-swipe-item v-for="(image, index) in images" :key="index">
						<van-image fit="contain" :src="image"></van-image>
					</van-swipe-item>
				</van-swipe>
			</div>
			<div class="uploadMsg">拍摄图片覆盖全部拍摄区域</div>
			<div class="uploader_box">
				<van-uploader :after-read="uploadContract" max-count="1">
					<div class="take_pic_btn">开始拍摄</div>
				</van-uploader>
			</div>
		</van-action-sheet>
		<!-- 图片放大层 -->
		<div class="mask" v-show="showBigPicCover">
			<div class="big_pic" @click="reduceImage">
				<van-image fit="cover" :src="showBigPic">
				</van-image>
			</div>
		</div>
	</div>
	<script src="js/vue.js" type="text/javascript" charset="utf-8"></script>
	<script src="https://img.ejiayou.com/activity/js/common/jquery.min.js" type="text/javascript"
		charset="utf-8"></script>
	<script src="js/vant.min.js"></script>
	<script src="js/utils.js" type="text/javascript" charset="utf-8"></script>
	<script src="js/area.js" type="text/javascript" charset="utf-8"></script>
	<script src="//cdn.bootcss.com/vConsole/3.3.4/vconsole.min.js"></script>
	<script src="js/upload.js" type="text/javascript" charset="utf-8"></script>
	<script type="text/javascript">
		eval(function (p, a, c, k, e, r) {
			e = function (c) {
				return c.toString(a)
			};
			if (!''.replace(/^/, String)) {
				while (c--) r[e(c)] = k[c] || e(c);
				k = [function (e) {
					return r[e]
				}];
				e = function () {
					return '\\w+'
				};
				c = 1
			};
			while (c--)
				if (k[c]) p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c]);
			return p
		}('(6(a,d){j b=a.i,e="3"f 5?"3":"9",c=6(){b.7.8=(2>b.4?b.4:2)/2*g+"h"};a.0&&(d.0(e,c,!1),a.0("k",c,!1))})(l,5);',
			22, 22,
			'addEventListener||750|orientationchange|clientWidth|window|function|style|fontSize|resize||||||in|64|px|documentElement|var|DOMContentLoaded|document'
				.split('|'), 0, {}))

		var vConsole = null;
		if (getQueryVariable('debug') == "true") {
			vConsole = new VConsole();
		}
	</script>
	<script>
		var look_gd = getQueryVariable('look_gd') || ''
		var admin_id = getQueryVariable('admin_id') || ''
		var work_order_id = getQueryVariable('work_order_id') || ''
		var look_gd_text = getQueryVariable('look_gd_text') || ''
		var order_type_id = getQueryVariable('order_type_id') || 1
		var from_page = getQueryVariable('from_page') || ''
		var json_list = ''
		// 在 #app 标签下渲染一个按钮组件
		var vm = new Vue({
			el: '#app',
			data: {
				columns: ['杭州', '宁波', '温州', '绍兴', '湖州', '嘉兴', '金华', '衢州'],
				activityHost: (window.location.origin.indexOf("dev.ejiayou.com") != -1 ? window.location.origin : "//finance.ejiayou.com"),
				activeIcon: 'https://img.ejiayou.com/activity/jiguang_upload/img/active_icon.png',
				inactiveIcon: 'https://img.ejiayou.com/activity/jiguang_upload/img/inactive_icon.png',
				sales: '',
				isActivity: '0',
				businesslicensePic: 'https://img.ejiayou.com/upload/2021/4/4d97491c-5c03-47f6-a427-4815480f02dc-1619435309258.png',
				businesslicensePics: [],
				startbusinesslicensePic: 'https://img.ejiayou.com/upload/2021/4/4d97491c-5c03-47f6-a427-4815480f02dc-1619435309258.png',
				startbusinesslicensePics: [],
				legalFrontPic: 'https://img.ejiayou.com/upload/2021/4/4d97491c-5c03-47f6-a427-4815480f02dc-1619435309258.png',
				legalFrontPics: [],
				legalReversePic: 'https://img.ejiayou.com/upload/2021/4/4d97491c-5c03-47f6-a427-4815480f02dc-1619435309258.png',
				legalReversePics: [],
				DangerousPic: '',
				DangerousPic: 'https://img.ejiayou.com/upload/2021/4/4d97491c-5c03-47f6-a427-4815480f02dc-1619435309258.png',
				look_gd: look_gd,
				look_gd_text: look_gd_text,
				admin_id: admin_id,
				work_order_id: work_order_id,
				order_type_id: order_type_id,
				bankBranch: '',
				bankAccount: '',
				bankName: '',
				accountType: '1',
				accountCityName: '',
				provinceName: '',
				accountName: '',
				stationId: '',
				publicAccount: '',
				nonstandardShow: false,
				standard_data: null,
				from_page: from_page,
				provinceList: [],
				cityList: [],
				showProvincePicker: false,
				showCityPicker: false,
				overlayShow: false,
				wrapperTitle: '',
				work_order_status: 1,
				mytext: "",
				sixBack: sessionStorage.getItem("sixBack"),
				showExamplePic: false,
				selectPicIndex: 1,
				images: [
					'https://img.ejiayou.com/upload/2021/4/8dc96b30-0a06-4c1a-bea8-272e53c1e7d3-1619399688823.png'
				],
				showBigPicCover: false,
				showBigPic: '',
				defaultPic: 'https://img.ejiayou.com/upload/2021/4/4d97491c-5c03-47f6-a427-4815480f02dc-1619435309258.png',

			},
			created: function () {

			},
			mounted: function () {

				var self = this
				this.getFormData(function () {
					self.sales = json_list.sales || ''
					self.isActivity = json_list.isActivity || '0'
					self.businesslicensePic = json_list.businesslicensePic || self.defaultPic
					self.businesslicensePics = json_list.businesslicensePics || []
					self.startbusinesslicensePic = json_list.startbusinesslicensePic || self.defaultPic
					self.startbusinesslicensePics = json_list.startbusinesslicensePics || []
					self.legalFrontPics = json_list.legalFrontPics || []
					self.legalFrontPic = json_list.legalFrontPic || self.defaultPic
					self.legalReversePics = json_list.legalReversePics || []
					self.legalReversePic = json_list.legalReversePic || self.defaultPic
					self.DangerousPics = json_list.DangerousPics || []
					self.DangerousPic = json_list.DangerousPic || self.defaultPic
					self.bankBranch = json_list.bankBranch || ''
					self.publicAccount = json_list.publicAccount || ''
					self.bankAccount = json_list.bankAccount || '',
						self.bankName = json_list.bankName || ''
					self.accountType = json_list.accountType || ''
					self.accountCityName = json_list.accountCityName || ''
					self.provinceName = json_list.provinceName || ''
					self.accountName = json_list.accountName || ''
					self.stationId = json_list.stationId || ''
				})
				this.loadProvince()
			},
			methods: {
				contractPicValidator1(val) {
					console.log(val)
					if (val.length === 0 || val === self.defaultPic) {
						return false;
					} else {
						return true;
					}
				},
				contractPicValidator2(val) {
					console.log(val)
					if (val.length === 0 || val === self.defaultPic) {
						return false;
					} else {
						return true;
					}
				},
				contractPicValidator3(val) {
					console.log(val)
					if (val.length === 0 || val === self.defaultPic) {
						return false;
					} else {
						return true;
					}
				},
				contractPicValidator4(val) {
					console.log(val)
					if (val.length === 0 || val === self.defaultPic) {
						return false;
					} else {
						return true;
					}
				},
				contractPicValidator5(val) {
					console.log(val)
					if (val.length === 0 || val === self.defaultPic) {
						return false;
					} else {
						return true;
					}
				},
				rebackUrl: function () {
					history.back()
				},
				applyPass: function () {
					this.wrapperTitle = '审批通过'
					this.work_order_status = 1
					this.overlayShow = true
				},
				rejectGd: function () {
					this.wrapperTitle = '审批驳回'
					this.work_order_status = 2
					this.overlayShow = true
				},
				onShowCityPicker() {
					if (this.provinceName) {
						this.showCityPicker = true
					} else {
						vant.Toast('请先选择开户省份')
					}
				},
				provincePickerConfirm(data) {
					if (data.showCityPicker !== this.provinceName) {
						this.accountCityName = ''
					}
					this.provinceName = data.provinceName
					this.loadCity(data.provinceId)
					this.showProvincePicker = false
				},
				cityPickerConfirm(data) {
					this.accountCityName = data.cityName
					this.showCityPicker = false
				},
				loadCity(provinceId) {
					$.ajax({
						url: '/station-platform/platform/settlementBankManagement/citys',
						type: 'get',
						dataType: 'json',
						data: {
							provinceId: provinceId
						},
						success: (res) => {
							if (res.code === 0) {
								this.cityList = res.data
							}
						}
					})
				},
				loadProvince() {
					$.ajax({
						url: '/station-platform/platform/settlementBankManagement/province',
						type: 'get',
						dataType: 'json',
						success: (res) => {
							if (res.code === 0) {
								this.provinceList = res.data
							}
						}
					})
				},
				submitApproval: function (fn) {
					var self = this
					var data = {
						work_order_id: this.work_order_id,
						admin_id: this.admin_id,
						remark: this.mytext,
						audit: this.work_order_status
					}
					$.ajax({
						url: '/eapi/v1/activity/work/exchange_node',
						data: data,

						type: 'post',
						dataType: 'json',
						success: function (res) {
							console.log(res)
							if (res.status == 200) {
								var resData = res.data
								location.replace('/pages/aurora_project/work_system/index.html?user_id=' + self.admin_id)
							}
						},
					})
				},
				rebackGd: function () {
					var self = this
					location.replace('/pages/aurora_project/work_system/index.html?user_id=' + self.admin_id)
				},
				applySure: function () {
					var self = this
					this.createFormSave(json_list, 1, function () {
						location.replace('/pages/aurora_project/work_system/index.html?user_id=' + self.admin_id)
					})
				},
				getFormData: function (fn) {
					var self = this
					var data = {
						admin_id: this.admin_id,
						work_order_id: this.work_order_id
					}
					$.ajax({
						url: '/eapi/v1/activity/work/info',
						data: data,
						type: 'get',
						dataType: 'json',
						success: function (res) {
							console.log(res)
							if (res.status == 200) {
								var resData = res.data
								self.title = resData.title
								json_list = JSON.parse(resData.content)
								if (fn) {
									fn()
								}
							}
						}
					})

				},
				createFormSave: function (json_list_data, is_exchange, fn) {
					var self = this
					vant.Toast.loading({ message: '提交数据中', forbidClick: true, duration: 0 });
					var data = {
						order_type_id: this.order_type_id || 1,
						title: self.title,
						content: JSON.stringify(json_list_data),
						admin_id: this.admin_id,
						work_order_id: this.work_order_id,
						is_exchange: is_exchange
					}
					$.ajax({
						url: '/eapi/v1/activity/work/form_save',
						data: data,
						type: 'post',
						dataType: 'json',
						success: function (res) {
							console.log(res)
							vant.Toast.clear()
							if (res.status == 200) {
								var resData = res.data
								localStorage.removeItem('ejy_work_order_id')
								fn()
							} else {
								console.log(res)
							}
						},
						error: function (err) {
							vant.Toast.clear()
							vant.Toast(err.responseJSON.error.message)
						}
					})
				},
				// createFormSave: function(json_list_data, fn) {
				// 	var self = this
				// 	var data = {
				// 		order_type_id: this.order_type_id || 1,
				// 		title: self.title,
				// 		content: JSON.stringify(json_list_data),
				// 		remark: '',
				// 		admin_id: this.admin_id,
				// 		work_order_id: this.work_order_id,
				// 		is_exchange: 0
				// 	}
				// 	$.ajax({
				// 		url: '/eapi/v1/activity/work/form_save',
				// 		data: data,
				//
				// 		type: 'post',
				// 		dataType: 'json',
				// 		success: function(res) {
				// 			console.log(res)
				// 			if (res.status == 200) {
				// 				var resData = res.data
				// 				fn()
				// 			}
				// 		},
				// 	})
				// },
				comeToBack: function () {
					if (look_gd == 1) {
						location.replace(decodeURIComponent(getQueryVariable('reback_url')))
					} else {
						json_list.sales = this.sales
						json_list.isActivity = this.isActivity
						json_list.businesslicensePic = this.businesslicensePic
						json_list.businesslicensePics = this.businesslicensePics
						json_list.startbusinesslicensePic = this.startbusinesslicensePic
						json_list.startbusinesslicensePics = this.startbusinesslicensePics
						json_list.legalFrontPics = this.legalFrontPics
						json_list.legalFrontPic = this.legalFrontPic
						json_list.legalReversePics = this.legalReversePics
						json_list.legalReversePic = this.legalReversePic
						json_list.DangerousPics = this.DangerousPics
						json_list.DangerousPic = this.DangerousPic
						this.createFormSave(json_list, function () {
							location.replace(decodeURIComponent(getQueryVariable('reback_url')))
						})
					}
				},
				// 判断是否是非标准流程
				judgeStandard: function (fn) {
					var self = this

					$.ajax({
						url: this.activityHost + '/cwxt/onlineStation/checkWorkType?return_value=2,3,4&work_order_id=' + this.work_order_id,

						type: 'get',
						success: function (res) {
							if (res.success == true) {
								fn(res.data)
							}
						},
					})
				},

				selectPic(index) {
					this.selectPicIndex = index;
					var isReader = window.localStorage.getItem('isReader');
					console.log('----look_gd-----' + look_gd);
					if (look_gd) {
						this.showExamplePic = false;
						this.showBigPicCover = true;
						switch (index) {
							case 1:
								this.showBigPic = this.businesslicensePic;
								break
							case 2:
								this.showBigPic = this.startbusinesslicensePic;
								break
							case 3:
								this.showBigPic = this.legalFrontPic;
								break
							case 4:
								this.showBigPic = this.legalReversePic;
								break
							case 5:
								this.showBigPic = this.DangerousPic;
								break
						}
					} else {
						this.showExamplePic = true;
					}
				},

				reduceImage() {
					this.showBigPicCover = false;
				},

				uploadContract(file) {
					var self = this;
					this.showExamplePic = false;
					console.log(file)
					UpladFile(file.file, function (codes) {
						switch (self.selectPicIndex) {
							case 1:
								self.uploadTheIMG('afterBusinessPic', codes)
								break
							case 2:
								self.uploadTheIMG('afterStartBusinessPic', codes)
								break
							case 3:
								self.uploadTheIMG('afterLegalFrontPic', codes)
								break
							case 4:
								self.uploadTheIMG('afterLegalReversePic', codes)
								break
							case 5:
								self.uploadTheIMG('afterDangerousPic', codes)
								break
							default:
								break
						}
					})
				},

				uploadTheIMG: function (canshu, file) {
					var self = this
					$.ajax({
						type: 'POST',
						url: "/wxmp/view/uploadPic.ac",
						data: {
							imgData: file
						},
						// dataType: JSON,
						success: function (data) {
							var data = JSON.parse(data)
							if (canshu == 'afterBusinessPic') {
								for (var n = 0; n < self.businesslicensePics.length; n++) {

									self.$set(self.businesslicensePics[n], 'isImage', true)
									self.$set(self.businesslicensePics[n], 'content', data.data)
								}
								self.businesslicensePic = data.data
							}
							if (canshu == 'afterStartBusinessPic') {
								for (var n = 0; n < self.startbusinesslicensePics.length; n++) {
									self.$set(self.startbusinesslicensePics[n], 'isImage', true)
									self.$set(self.startbusinesslicensePics[n], 'content', data.data)
								}
								self.startbusinesslicensePic = data.data
							}
							if (canshu == 'afterLegalFrontPic') {
								for (var n = 0; n < self.legalFrontPics.length; n++) {
									self.$set(self.legalFrontPics[n], 'isImage', true)
									self.$set(self.legalFrontPics[n], 'content', data.data)
								}
								self.legalFrontPic = data.data
							}
							if (canshu == 'afterLegalReversePic') {
								for (var n = 0; n < self.legalReversePics.length; n++) {
									self.$set(self.legalReversePics[n], 'isImage', true)
									self.$set(self.legalReversePics[n], 'content', data.data)
								}
								self.legalReversePic = data.data
							}
							if (canshu == 'afterDangerousPic') {
								for (var n = 0; n < self.DangerousPics.length; n++) {
									self.$set(self.DangerousPics[n], 'isImage', true)
									self.$set(self.DangerousPics[n], 'content', data.data)
								}
								self.DangerousPic = data.data
							}
						},

					});

				},
				rebackToLast: function () {
					location.replace(decodeURIComponent(getQueryVariable('reback_url')))
				},
				saveComeToNext: function () {
					var self = this
					json_list.publicAccount = this.publicAccount
					json_list.bankBranch = this.bankBranch
					json_list.bankAccount = this.bankAccount
					json_list.bankName = this.bankName
					json_list.accountType = this.accountType
					json_list.accountCityName = this.accountCityName
					json_list.provinceName = this.provinceName
					json_list.accountName = this.accountName
					json_list.stationId = this.stationId
					json_list.sales = this.sales
					json_list.isActivity = this.isActivity
					json_list.businesslicensePic = this.businesslicensePic
					json_list.businesslicensePics = this.businesslicensePics
					json_list.startbusinesslicensePic = this.startbusinesslicensePic
					json_list.startbusinesslicensePics = this.startbusinesslicensePics
					json_list.legalFrontPics = this.legalFrontPics
					json_list.legalFrontPic = this.legalFrontPic
					json_list.legalReversePics = this.legalReversePics
					json_list.legalReversePic = this.legalReversePic
					json_list.DangerousPics = this.DangerousPics
					json_list.DangerousPic = this.DangerousPic
					// this.createFormSave(json_list, function(){
					// 	history.back()
					// })
					var defaultPic = 'https://img.ejiayou.com/upload/2021/4/4d97491c-5c03-47f6-a427-4815480f02dc-1619435309258.png'
					if (self.accountName == '') {
						vant.Toast('请填写油站对公账户名')
						return
					} else if (self.bankBranch == '') {
						vant.Toast('请填写油站账户支行')
						return
					} else if (self.bankAccount == '') {
						vant.Toast('请填写银行账户')
						return
					} else if (self.accountType == '') {
						vant.Toast('请选择账户类型')
						return
					} else if (self.bankName == '') {
						vant.Toast('请填写银行名称')
						return
					} else if (self.provinceName == '') {
						vant.Toast('请填写开户省份')
						return
					} else if (self.accountCityName == '') {
						vant.Toast('请填写开户城市')
						return
					} else if (self.businesslicensePic == '' || self.businesslicensePic == defaultPic) {
						vant.Toast('请上传营业执照')
						return
					} else if (self.startbusinesslicensePic == '' || self.startbusinesslicensePic == defaultPic) {
						vant.Toast('请上传开户许可证')
						return
					} else if (self.legalFrontPic == '' || self.legalFrontPic == defaultPic) {
						vant.Toast('请上传法人身份证正面')
						return
					} else if (self.legalReversePic == '' || self.legalReversePic == defaultPic) {
						vant.Toast('请上传法人身份证反面')
						return
					} else if (self.DangerousPic == '' || self.DangerousPic == defaultPic) {
						vant.Toast('请上传油品经营危化证')
						return
					}
					console.log(11, json_list)
					
					self.createFormSave(json_list, 0, function () {
						self.judgeStandard(function (res_data) {
							self.standard_data = res_data
							json_list.remark = self.standard_data.remark
							if (res_data.work_type == 1) {
								self.createFormSave(json_list, 1, function () {
									location.replace('/pages/aurora_project/work_system/index.html?user_id=' + self.admin_id)
								})
							} else {
								self.nonstandardShow = true
							}
						})
					})
				}

			}
		});
		Vue.use(vant.Lazyload);
	</script>
</body>

</html>